<?php
// =====================================================
// AnthroHeart - High Integrity Unique IP Counter
// =====================================================
$counter_file = __DIR__ . '/visitors.txt';
$unique_file  = __DIR__ . '/unique_visitors.txt';

if (!file_exists($counter_file)) { file_put_contents($counter_file, "0", LOCK_EX); }
if (!file_exists($unique_file)) { file_put_contents($unique_file, serialize([]), LOCK_EX); }

$count_raw = @file_get_contents($counter_file);
$count = is_string($count_raw) ? (int)trim($count_raw) : 0;

$ip = $_SERVER['REMOTE_ADDR'] ?? 'unknown';
$date = date('Y-m-d');
$visitor_key = hash('sha256', $ip . '|' . $date);

$unique_raw = @file_get_contents($unique_file);
$unique_visitors = @unserialize($unique_raw);
if (!is_array($unique_visitors)) { $unique_visitors = []; }

if (!in_array($visitor_key, $unique_visitors, true)) {
    $unique_visitors[] = $visitor_key;
    $count++;
    file_put_contents($counter_file, (string)$count, LOCK_EX);
    file_put_contents($unique_file, serialize($unique_visitors), LOCK_EX);
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>AnthroHeart Universe – A Public Domain Mythos</title>
  
  <!-- SEO & Social Previews -->
  <meta name="description" content="147 songs · 23 characters · Full Lore · 100% Public Domain. A Studio-in-a-Box gift to humanity.">
  <meta property="og:title" content="AnthroHeart Universe – Public Domain Studio-in-a-Box">
  <meta property="og:description" content="Mythic. Musical. Free forever. Anchored to the Bitcoin Blockchain.">
  <meta property="og:image" content="https://anthroheart.com/blueheart.png">
  <meta property="og:url" content="https://anthroheart.com/">
  <meta name="twitter:card" content="summary_large_image">

  <link href="https://fonts.googleapis.com/css2?family=Cinzel:wght@700&family=Montserrat:wght@400;600&family=Fira+Code&display=swap" rel="stylesheet">
  
  <style>
    :root {
      --gold: #d4af37;
      --soft-gold: #f4e5a1;
      --bg-dark: #0f0a05;
      --text-color: #ffebcd;
      --terminal-green: #00ff00;
    }

    body { margin:0; font-family:'Montserrat', sans-serif; background: var(--bg-dark); color: var(--text-color); line-height: 1.6; overflow-x: hidden; }
    
    /* --- Layout Elements --- */
    .container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }
    section { padding: 60px 0; border-bottom: 1px solid rgba(212,175,55,0.1); }
    h1, h2, h3 { font-family: 'Cinzel', serif; text-align: center; color: var(--gold); text-shadow: 0 0 15px rgba(212,175,55,0.4); }
    
    /* --- Hero / Marquee --- */
    .marquee-hero {
      position: relative; width: 100%; height: 80vh; min-height: 500px; background: #000; border-bottom: 5px solid var(--gold);
    }
    .marquee-frame {
      position: absolute; inset: 0; z-index: 3; pointer-events: none; border: 15px solid var(--gold);
      box-shadow: 0 0 30px rgba(255,215,0,0.5), inset 0 0 20px rgba(0,0,0,0.8);
    }

    /* --- Access Nodes (The Technical Heart) --- */
    .node-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; margin: 40px 0; }
    .node-card {
      background: linear-gradient(180deg, #1a0f06, #2b1b0a);
      border: 2px solid var(--gold); border-radius: 12px; padding: 25px; text-align: center;
      text-decoration: none; color: var(--text-color); transition: 0.3s; flex: 1 1 300px;
    }
    .node-card:hover { transform: translateY(-5px); box-shadow: 0 0 30px var(--gold); }

    /* --- Media scaling --- */
    img { max-width: 100%; height: auto; border-radius: 8px; box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
    .video-wrapper { position: relative; padding-bottom: 56.25%; height: 0; margin: 30px 0; border-radius: 12px; overflow: hidden; border: 2px solid var(--gold); }
    .video-wrapper iframe { position: absolute; top:0; left:0; width: 100%; height: 100%; }

    /* --- Terminal Box --- */
    .terminal {
      background: #001a00; border: 2px solid var(--terminal-green); border-radius: 10px;
      padding: 20px; font-family: 'Fira Code', monospace; color: var(--terminal-green);
      box-shadow: 0 0 20px rgba(0,255,0,0.2); overflow-x: auto;
    }

    /* --- Buttons --- */
    .btn-gold {
      display: inline-block; padding: 15px 40px; background: linear-gradient(45deg, #b8860b, #ffd700);
      color: #2b1b0a; font-weight: bold; text-decoration: none; border-radius: 50px;
      text-transform: uppercase; letter-spacing: 1px; transition: 0.3s;
    }
    .btn-gold:hover { transform: scale(1.05); box-shadow: 0 0 25px var(--gold); }

    /* --- Info Boxes --- */
    .notice-box {
      background: rgba(255, 235, 205, 0.05); border-left: 5px solid var(--gold);
      padding: 30px; border-radius: 0 12px 12px 0; margin: 40px 0;
    }

    footer { background: #000; padding: 60px 20px; text-align: center; border-top: 5px solid var(--gold); }
    
    .stats-badge {
      font-size: 3rem; color: var(--terminal-green); text-shadow: 0 0 15px var(--terminal-green);
      margin: 20px 0; display: block;
    }
  </style>
</head>
<body>

  <!-- HERO VIDEO SECTION -->
  <div class="marquee-hero">
    <div class="marquee-frame"></div>
    <iframe
        src="https://www.youtube.com/embed/l93bUo1imXE?autoplay=1&mute=1&loop=1&playlist=l93bUo1imXE&controls=0&modestbranding=1"
        style="width:100%; height:100%; border:none;"
        allow="autoplay; encrypted-media">
    </iframe>
    <div style="position:absolute; bottom: 10%; width: 100%; text-align:center; z-index:4;">
        <h1 style="font-size: 3.5rem; margin:0;">ANTHROHEART UNIVERSE</h1>
        <p style="font-size: 1.5rem; background: rgba(0,0,0,0.6); display:inline-block; padding: 10px 30px; border-radius: 50px;">A Gift to Humanity from Thomas B Sweet</p>
    </div>
  </div>

  <div class="container">

    <!-- GENESIS MISSION -->
    <section>
      <h2>The Purpose</h2>
      <div class="notice-box">
        <p style="font-size: 1.2rem;"><strong>AnthroHeart Universe is a complete “Studio-in-a-Box” creative franchise released fully into the Public Domain.</strong></p>
        <p>Take 147 songs, 23 characters, and a massive trilogy of lore. Build your own movies, games, or art. Disney can use it, you can use it, the world owns it now.</p>
        <p><em>"I have awakened from the Dream and now walk in the Completion Field."</em></p>
      </div>
    </section>

    <!-- INFRASTRUCTURE NODES -->
    <section>
      <h2>✦ THE ACCESS NODES ✦</h2>
      <p style="text-align:center; opacity: 0.8;">High-velocity distribution seeding from IONOS 1.5Gbps backbone.</p>
      <div class="node-grid">
        <a href="https://anthroheart.com/index.php" class="node-card">
          <div style="font-size: 3rem;">📦</div>
          <h3>The Collection Bundle</h3>
          <p>Download the 5.33GB Full Archive (7z, Torrent, JSON Proofs)</p>
        </a>
        <a href="http://archive.anthroentertainment.com" class="node-card">
          <div style="font-size: 3rem;">🏛️</div>
          <h3>Internet Archive</h3>
          <p>Permanent mirror and browser-based preview.</p>
        </a>
      </div>
      <div style="text-align:center; margin-top:20px;">
        <a href="https://anthroentertainmentllc.itch.io/" class="btn-gold">Explore on itch.io</a>
      </div>
    </section>

    <!-- THE PITCH DECK -->
    <section>
      <h2>The Vision: Pitch Deck</h2>
      <p style="text-align:center;">The 14-page document that outlines 14 trillion dimensions of lore.</p>
      <div class="video-wrapper" style="padding-bottom: 120%; border:none;">
        <embed src="AnthroHeart_Deck.pdf" type="application/pdf" width="100%" height="100%" />
      </div>
      <div style="text-align:center;">
         <a href="AnthroHeart_Pitch_Deck.pdf" target="_blank" class="btn-gold" style="font-size: 1rem;">Open Full PDF</a>
      </div>
    </section>

    <!-- MEMORIES & TRADITIONAL ART -->
    <section>
      <h2>Memories in My Pencil</h2>
      <div style="text-align:center; margin-bottom: 40px;">
        <img src="images/SherryDrawing.jpg" alt="Sherry Pencil Drawing" style="max-width: 500px; border: 4px solid var(--gold);">
        <p style="margin-top:20px; font-style: italic; color: var(--gold);">Sherry: "Kiss my rose." — Drawn by hand, graphite on paper.</p>
      </div>
      <p>Every story in this bundle started with real humans. From Kelly Stricker and her quarter horses to the rubber-band wars in the Training department, these pencil lines remember every laugh and every struggle. I stayed home and built this 10GB universe while the world got weird. I gave it away because the soul belongs to the people.</p>
    </section>

    <!-- THE GENESIS MACHINE -->
    <section>
      <h2>My First Computer — Age 7</h2>
      <div style="text-align:center;">
        <img src="images/computer.jpg" alt="VTech PreComputer 1000" style="max-width: 600px; border: 4px solid #4169e1;">
        <p style="color: #87cefa;">The VTech PreComputer 1000 (1988). 2 KB RAM. Where I learned to code.</p>
      </div>
      <div class="terminal" style="margin-top:30px;">
        <p>10 PRINT "How many French fries did you eat?"<br>
        20 INPUT F<br>
        30 PRINT "How many inches was each French fry?"<br>
        40 INPUT I<br>
        50 PRINT "You just ate a "; F*I;" inch French fry."<br>
        60 END</p>
      </div>
      <p style="text-align:center; margin-top:20px;">Peak comedy achieved at age 7. Chasing that high ever since.</p>
    </section>

    <!-- TRADEMARK & IDENTITY -->
    <section>
      <h2>Legal Sovereignty</h2>
      <div class="notice-box" style="border-color: #00f2ff;">
        <h3>Trademark Status</h3>
        <p>Anthro Entertainment LLC is operating under common-law trademark rights since 2019. By releasing the IP into the Public Domain, I am ensuring its integrity remains un-shoppable by corporate trolls.</p>
        <p><strong>Release Proof:</strong> Anchored to Bitcoin Block #929481.</p>
      </div>
    </section>

    <!-- FINANCIAL TRANSPARENCY -->
    <section>
      <h2>🐾 Sovereignty over Debt</h2>
      <p>I built this from the ground up on disability. Goblin lenders offered me $10,000 at 126% interest. I said no. No VC, no debt, no games. Just the Heart.</p>
      <div style="text-align:center; padding: 40px; background: #1a0f06; border: 2px solid var(--gold); border-radius: 20px;">
        <h3>Support the Legacy</h3>
        <p>Starting a business checking account with a $25 balance. No pressure, just transparency.</p>
        <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=healing@intentionrepeater.com&currency_code=USD" class="btn-gold">Send Love via PayPal</a>
      </div>
    </section>

    <!-- METLIFE TRIBUTE -->
    <section>
        <div style="background: #fff; color: #333; padding: 30px; border-radius: 12px; border-left: 10px solid #0071c5;">
            <h2 style="color: #0071c5; text-align:left; text-shadow:none;">Thank You, MetLife</h2>
            <p>"Get Met. It Pays." — It truly does. MetLife supported me when I was building something from nothing. I am deeply grateful for their role in my independence.</p>
            <p style="text-align:right; font-style:italic;">– Anthro Entertainment LLC</p>
        </div>
    </section>

  </div> <!-- End Container -->

  <footer>
    <div class="container">
      <div class="terminal" style="display:inline-block; padding: 10px 40px; margin-bottom: 20px;">
        <span class="stats-badge"><?= number_format($count) ?></span>
        Unique souls have discovered the Heart.
      </div>
      <p>© 2025 Thomas B Sweet · Public Domain · Anchored to the Blockchain</p>
      <p style="opacity: 0.5; font-size: 0.8rem;">BBR-Optimized Seeding Node active at 69.48.205.55</p>
    </div>
  </footer>

</body>
</html>
